<?php

namespace Sifast\ProjectBundle\Entity;

use Doctrine\ORM\Mapping as ORM;

/**
 * Profil
 *
 * @ORM\Table()
 * @ORM\Entity(repositoryClass="Sifast\ProjectBundle\Entity\ProfilRepository")
 */
class Profil
{
    /**
     * @var integer
     *
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * @var string
     *
     * @ORM\Column(name="nom_profil", type="string", length=255)
     */
    private $nomProfil;

    /**
     * @var string
     *
     * @ORM\Column(name="code_profil", type="string", length=255)
     */
    private $codeProfil;

    /**
     * @var integer
     *
     * @ORM\Column(name="ordre_tri", type="integer")
     */
    private $ordreTri;

    /**
     * @var string
     *
     * @ORM\Column(name="description", type="text")
     */
    private $description;

    /**
     * @var string
     *
     * @ORM\Column(name="type", type="string", length=255)
     */
    private $type;

    /**
     * @var string
     *
     * @ORM\Column(name="date_debut", type="string", length=255)
     */
    private $dateDebut;

    /**
     * @var string
     *
     * @ORM\Column(name="date_fin", type="string", length=255)
     */
    private $dateFin;

    /**
    * @var Role 
    * @ORM\ManyToMany(targetEntity="Role", mappedBy="Profil")
    */
    private $idRole;
    /**
     * Get id
     *
     * @return integer 
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Set nomProfil
     *
     * @param string $nomProfil
     * @return Profil
     */
    public function setNomProfil($nomProfil)
    {
        $this->nomProfil = $nomProfil;
    
        return $this;
    }

    /**
     * Get nomProfil
     *
     * @return string 
     */
    public function getNomProfil()
    {
        return $this->nomProfil;
    }

    /**
     * Set codeProfil
     *
     * @param string $codeProfil
     * @return Profil
     */
    public function setCodeProfil($codeProfil)
    {
        $this->codeProfil = $codeProfil;
    
        return $this;
    }

    /**
     * Get codeProfil
     *
     * @return string 
     */
    public function getCodeProfil()
    {
        return $this->codeProfil;
    }

    /**
     * Set ordreTri
     *
     * @param integer $ordreTri
     * @return Profil
     */
    public function setOrdreTri($ordreTri)
    {
        $this->ordreTri = $ordreTri;
    
        return $this;
    }

    /**
     * Get ordreTri
     *
     * @return integer 
     */
    public function getOrdreTri()
    {
        return $this->ordreTri;
    }

    /**
     * Set description
     *
     * @param string $description
     * @return Profil
     */
    public function setDescription($description)
    {
        $this->description = $description;
    
        return $this;
    }

    /**
     * Get description
     *
     * @return string 
     */
    public function getDescription()
    {
        return $this->description;
    }

    /**
     * Set type
     *
     * @param string $type
     * @return Profil
     */
    public function setType($type)
    {
        $this->type = $type;
    
        return $this;
    }

    /**
     * Get type
     *
     * @return string 
     */
    public function getType()
    {
        return $this->type;
    }

    /**
     * Set dateDebut
     *
     * @param string $dateDebut
     * @return Profil
     */
    public function setDateDebut($dateDebut)
    {
        $this->dateDebut = $dateDebut;
    
        return $this;
    }

    /**
     * Get dateDebut
     *
     * @return string 
     */
    public function getDateDebut()
    {
        return $this->dateDebut;
    }

    /**
     * Set dateFin
     *
     * @param string $dateFin
     * @return Profil
     */
    public function setDateFin($dateFin)
    {
        $this->dateFin = $dateFin;
    
        return $this;
    }

    /**
     * Get dateFin
     *
     * @return string 
     */
    public function getDateFin()
    {
        return $this->dateFin;
    }
    /**
     * Constructor
     */
    public function __construct()
    {
        $this->idRole = new \Doctrine\Common\Collections\ArrayCollection();
    }
    
    /**
     * Add idRole
     *
     * @param \Sifast\ProjectBundle\Entity\Role $idRole
     * @return Profil
     */
    public function addIdRole(\Sifast\ProjectBundle\Entity\Role $idRole)
    {
        $this->idRole[] = $idRole;
    
        return $this;
    }

    /**
     * Remove idRole
     *
     * @param \Sifast\ProjectBundle\Entity\Role $idRole
     */
    public function removeIdRole(\Sifast\ProjectBundle\Entity\Role $idRole)
    {
        $this->idRole->removeElement($idRole);
    }

    /**
     * Get idRole
     *
     * @return \Doctrine\Common\Collections\Collection 
     */
    public function getIdRole()
    {
        return $this->idRole;
    }
}